import Vue from 'vue'
import Router from 'vue-router'

const Home = () => import('../views/home/Home')
const Cart = () => import('../views/cart/Cart')
const Categorys = () => import('../views/categorys/Categorys')
const Profile = () => import('../views/profile/ProFile')

Vue.use(Router)

const routes = [
  {
    path:'',
    redirect:'/home'
  },
  {
    path: '/home',
    component: Home,
  },
  {
    path: '/cart',
    component: Cart
  },
  {
    path: '/categorys',
    component: Categorys
  },
  {
    path: '/profile',
    component: Profile
  }
]
const router = new Router({
  routes,
  model:'history'
})

export default router